{% extends 'TopxiaWebBundle::layout.html.twig' %}

{% set script_controller = 'mobile/index' %}
{% set isEsApp = (mobileCode == 'edusohov3') %}

{% block title %}{{'移动学习'|trans}} - {{ parent() }}{% endblock %}

{% block full_content %}
  <div class="es-mobile">
    <div class="js-mobile-item mobile-first">
      <div class="container">
        <img class="img-one hidden-xs" src="{{asset("assets/v2/img/mobile/phone_black.png")}}" alt="">
        <div class="img-two hidden-xs">
          <img class="img-two-bg" src="{{asset("assets/v2/img/mobile/phone_white_bg.png")}}" alt="">
          {% if setting('mobile.appcover') %}
          <img class="img-two-content" src="{{asset(setting('mobile.appcover'))}}" alt="">
          {% else %}
          <img class="img-two-content" src="{{asset("assets/v2/img/mobile/phone_white_content.png")}}" alt="">
          {% endif %}
        </div>
        <div class="mobile-content">
          <div class="title">
            {% if setting('mobile.applogo') %}
              <img src="{{asset(setting('mobile.applogo'))}}" alt="">
            {% else %}
              <img src="{{asset("assets/v2/img/mobile/app_logo.png")}}" alt="">
            {% endif %}
            
            {% if not isEsApp %}
              {{mobile.appname|default('阔知学堂'|trans)}}
            {% else %}
              {{'阔知学堂'|trans}}
            {% endif %}
          </div>
          <div class="subtitle">
            {% if not isEsApp %}
              {{mobile.appabout|default(' 将学校装进口袋，移动学习，随时随地。'|trans)}}
            {% else %}
               {{'将学校装进口袋，移动学习，随时随地。'|trans}}
            {% endif %}
          </div>
          <a class="btn-mobile" href="javascript:;" data-url=".mobile-second">{{'下载APP'|trans}}<i class="es-icon es-icon-filedownload"></i></a>

          {% if isEsApp %}
          <a class="btn-mobile" href="javascript:;" data-url=".mobile-third">{{'登录网校'|trans}}<i class="es-icon es-icon-phone1"></i></a>
          {% endif %}
        </div>
      </div>
    </div>
    <div class=" mobile-second">
      <div class="container">
        <div class="step">
          {% if mobileCode == 'edusohov3' %}<span class="member">1</span>{{'第一步:'|trans}}{% endif %} {{'扫描二维码，下载手机APP。'|trans}}
        </div>
        <div class="row">
          <div class="col-sm-6 text-center">
            <img class="qrcode" src="{{ path('mobile_download_qrcode',{code:mobileCode}) }}" alt="">
          </div>
          <div class="col-sm-6 text-center">
            <a href="{{ path('mobile_download', {client:'android',code:mobileCode}) }}" class="btn-android"><i class='es-icon es-icon-android'></i>Android {{'客户端'|trans}}</a>
            <a href="{{ path('mobile_download', {client:'iphone',code:mobileCode}) }}" class="btn-apple"><i class='es-icon es-icon-apple'></i>iPhone{{'客户端'|trans}}</a>
          </div>
        </div>
      </div>
    </div>
    {% if isEsApp %}
    <div class="js-mobile-item mobile-third">
      <div class="container">
        <div class="step">
          <span class="member">2</span>{{'第二步: 打开阔知学堂APP，扫描网校二维码。'|trans}}
        </div>
        <div class="row">
          <div class="col-sm-6 text-center">
            <img class="thumb" src="{{asset("assets/v2/img/mobile/phone_gui.png")}}" alt="">
          </div>
          <div class="col-sm-6 text-center">
            <div class="qrcode">
              <p>{{'扫一扫登录客户端'|trans}}</p>
              <img src="{{ path('topxia_mobile_qrcode') }}" alt="">
            </div>
            {% if app.user %}
                <p class="text-danger">*该二维码附带账号信息，请不要分享给他人</p>
            {% endif %}
          </div>
        </div>
      </div>
    </div>
    {% endif %}
  </div>
{% endblock %}